Point

Draw calls tend to have bigger impact on performance than poly counts. It is important to understand what draw calls are when it comes to optimization.

What is a Draw call?

UE4 definition:A group of polygons that shares the same material.

The number of draw calls and the number of meshes are not equal. Let\’s take a look at the example of 2 tetragons below. They are the same mesh, but the left one has 2 materials and the right one has 1 material. In this case the left one has 2 draw calls and the right one has 1 draw call.

draw calls

Note that things like a blueprint component is one of draw calls. Also even if the project is empty, they are a dozens of them because of how real-time rendering is set up.

› PC & console games

  • 2000~3000 is ideal 
  • 5000~ starts to have promlems
  • 10000~ probably is a problem

› Mobile & VR games

  • Max is a few handreds

How many is too many?

You cannot say for certain when problems occur because it depends on your contents and your target platform. Also draw call is not the only factor in performance and you need to consider other factors such as pixel shader. The numbers below are just a rough estimate and again, it depends on what kind of game you\’re making.

How to check?

 ›  stat RHI

  • You can check the number of mesh draw calls. It shows the number of every draw call generated by mesh.

 

 ›  stat sceneRendering

  • You can check the number of draw primitive calls, which is a total number of every draw call in a scene.

 

 ›  how to execute a command

  • Press ’Tab’ or ’Tilde (~)’ then enter a command

 

 ›  how to disable a command 

  • Either enter the same command  or enter ’stat none’

Why should I have less draw calls?

It\’s not about draw call itself, it\’s about how computers handle it. X number of triangles are transferred to GPU per draw call, and the same rendering state will be applied to these triangles. So for example, if there was the same number of draw calls, it is faster to transfer 1,000,000 tries one time than 100 tris 1000 times. Because GPU has to stop and wait for CPU to transfer next set of information.

Simply put, let\’s say you have $100 at bank and you want to bring back home. It is faster to withdraw $100 at once than to withdraw $1 each time and having to go back and forth from home and bank many times.

 

For official documentation by Epic Games, click here.